// TencentRtcPlugin.m
// Created by lexuslin on 2020/11/19
// Copyright (c) 2020年 Tencent. All rights reserved.
#import "TencentRtcPlugin.h"
#if __has_include(<tencent_trtc_cloud/tencent_trtc_cloud-Swift.h>)
#import <tencent_trtc_cloud/tencent_trtc_cloud-Swift.h>
#else
// Support project import fallback if the generated compatibility header
// is not copied when this plugin is created as a library.
// https://forums.swift.org/t/swift-static-libraries-dont-copy-generated-objective-c-header/19816
#import "tencent_trtc_cloud-Swift.h"
#endif

// #import "RtmpTencentFactory.h"
// #import "TXLiteAVSDK_Professional/TXLiteAVSDK.h"
// #import "VideoTencentFactory.h"


// 接口定义
@implementation TencentRtcPlugin
+ (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar>*)registrar {
  [TencentTRTCCloud registerWithRegistrar:registrar];
  //FlutterMethodChannel* channel = [FlutterMethodChannel methodChannelWithName:@"rtmp_tencent_live_flutter" binaryMessenger:[registrar messenger]];
  //  RtmpTencentLivePlugin* instance = [[RtmpTencentLivePlugin alloc] init];
  //  [registrar addMethodCallDelegate:instance channel:channel];
  //  [registrar registerViewFactory:[[RtmpTencentFactory alloc] initWithMessager:registrar.messenger]withId:@"TencentLive"];
  //  [registrar registerViewFactory:[[VideoTencentFactory alloc] initWithMessager:registrar.messenger]withId:@"TencentVideoLive"];
}

//- (void)handleMethodCall:(FlutterMethodCall*)call result:(FlutterResult)result {
//  if ([@"setLicence" isEqualToString:call.method]) {
//      NSDictionary *info = call.arguments;
//      NSLog(@"qewqe");
//      [TXLiveBase setLicenceURL:info[@"url"] key:info[@"key"]];
//      NSLog(@"SDK Version = %@", [TXLiveBase getSDKVersionStr]);
// }
//}

@end
